Skip to content

Fixing BCIT and in app tests in CI#1048

Open
franco-zalamena-iterable wants to merge 9 commits into
masterfrom
SDK-170-emulator-network-trace
Open

Fixing BCIT and in app tests in CI#1048
franco-zalamena-iterable wants to merge 9 commits into
masterfrom
SDK-170-emulator-network-trace

Conversation

@franco-zalamena-iterable
Copy link
Copy Markdown
Contributor

@franco-zalamena-iterable franco-zalamena-iterable commented Apr 28, 2026

🔹 Jira Ticket(s) if any

✏️ Description

This PR is meant to fix constant failures on the E2E-In-app testing and Instrumental tests.

The fix is centered around updating the engine the tests are running on and some minor lookup fixes in some tests.

We also have better diagnostics now for the failures on emulator

actions/setup-java@v1.4.3 was resolving java-version: 17 through the
deprecated AdoptOpenJDK API. Between Apr 21 and Apr 22 that resolution
shifted from 17.0.18 to 17.0.19, and the artifact returned for 17.0.19
makes sdkmanager exit immediately, breaking the emulator-runner action's
Install Android SDK step on every run since.

Upgrade setup-java to v4.8.0 with distribution: temurin so the JDK is
pinned to a deterministic Adoptium Temurin build, and replace the
deprecated gradle/wrapper-validation-action with gradle/actions/wrapper-validation@v4.
Applied to all three jobs (check, unit-tests, instrumentation-tests).

Co-authored-by: Cursor <cursoragent@cursor.com>
scripts/trace-bcit.sh and the integration-tests printBuildConfig Gradle task
were used for local replication while diagnosing SDK-170. They are not invoked
by CI. Removing them keeps the PR diff focused on what actually fixes the
in-app E2E job.

Co-authored-by: Cursor <cursoragent@cursor.com>
The previous CI run on macos-15-intel (2 cores / 3GB AVD on HVF) starved
system_server during cold boot. Logcat shows continuous ANRs in systemui,
nexuslauncher, gms.persistent, googlequicksearchbox, com.android.phone,
com.google.android.as, keychain, permissioncontroller — all before and
during the test. UiAutomator's wait then timed out with current package =
'android' (a system dialog) sitting on top of MainActivity, so btnInAppMessages
was unreachable.

Switching to ubuntu-latest with KVM acceleration gives the AVD real
hardware virtualization on a 4 vCPU / 16GB host, stopping the ANR storm
and letting the test see MainActivity within its 30s wait.

Co-authored-by: Cursor <cursoragent@cursor.com>
The Integration Tests workflow has never produced a green run since it
was added in July 2025 (481 runs, 0 successes). When the emulator fails
to boot (which is now the steady state on macos-latest Apple Silicon),
the always-on `Collect Test Logs` step calls `adb logcat -d` which
blocks indefinitely waiting for a device that never appears. The job
then sits for the full 6h GitHub Actions job timeout on every nightly
cron and every PR run.

Add step-level timeouts and `|| true` so the failure is fast and the
workflow doesn't waste 6h of runner time on every failed run. This
doesn't make Integration Tests pass — that requires a proper refactor
to ReactiveCircus/android-emulator-runner@v2 on Ubuntu+KVM (separate
follow-up) — but it stops the nightly resource bleed today.

Co-authored-by: Cursor <cursoragent@cursor.com>
@franco-zalamena-iterable franco-zalamena-iterable force-pushed the SDK-170-emulator-network-trace branch from ebba543 to 664f21d Compare May 11, 2026 15:24
@franco-zalamena-iterable franco-zalamena-iterable marked this pull request as ready for review May 11, 2026 16:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant